﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.Text;
using CS.WinService;
using NUnit.Framework;

namespace NUnit
{
    [TestFixture]
    public class Temp
    {
        [Test]
        public void ConfigSerTest()
        {
            //var config = new TaskConfig();
            //config.Resources = new ResourceCollection();
            //ResParamCollection pras = new ResParamCollection();
            //pras.Add(new ResParamInfo() { Key = "mykey", Value = "myValue" });
            //pras.Add(new ResParamInfo() { Key = "mykey2", Value = "myValu2e" });
            //config.Resources.Add(new ResourceInfo() { Name = "temp", Value = "test.value", Params = pras });

            var config = TaskConfig.GetInstance();


            var val = config.ToXml();

            Console.WriteLine(config.Resources["key1"].Value);

            //Console.WriteLine(val);

        }


        [Test]
        public void ExtendInfoTest()
        {
            var ext = new ExtendInfo();
            ext.Settings = new ParamCollection();

            ext.Settings.Add(new ParamInfo("temp","tempx"));
            


            var xml = ext.ToXml();

            Console.Write(xml);

        }

        [Test]
        public void TimeTest()
        {
            var now = DateTime.Now;
            var s = string.Format("{0:u}", now);
            Console.WriteLine(s);
        }


    }
}
